package com.example.springbott.bean.zeng;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@AllArgsConstructor
@Data
@NoArgsConstructor
public class BaseRespVoInDelete {
    String errmsg;
    int errno;

    public static BaseRespVoInDelete ok() {
        BaseRespVoInDelete baseRespVo = new BaseRespVoInDelete();
        baseRespVo.setErrmsg("成功");
        return baseRespVo;
    }

    public static BaseRespVoInDelete fail(String errmsg, Integer errorCode) {
        BaseRespVoInDelete baseRespVo = new BaseRespVoInDelete(errmsg, errorCode);

        return baseRespVo;
    }

    public static BaseRespVoInDelete invalidData(String msg) {
        BaseRespVoInDelete baseRespVo = new BaseRespVoInDelete();
        baseRespVo.setErrno(504);
        baseRespVo.setErrmsg(msg);
        return baseRespVo;
    }
}
